package com.sdutcm.Service.ServiceImpl;

/*
 *@Author Yan
 *@Create 2019-08-28 11:08
 */

import com.sdutcm.Mapper.RealmMapper;
import com.sdutcm.Service.RealmService;
import com.sdutcm.Shiro.Role;
import com.sdutcm.Shiro.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RealmServiceImpl implements RealmService {

    @Autowired
    private RealmMapper realmMapper;

    @Override
    public User findByUsername(String username) {
        return realmMapper.findByUsername(username);
    }

    @Override
    public List<Role> selectRoleList(String username) {
        return realmMapper.selectRoleList(username);
    }
}
